package com.coding.pojo;

import java.io.Serializable;

/**
 * post
 * @author 
 */
public class PostKey implements Serializable {
    private Integer post_id;

    private Integer post_user_id;

    private static final long serialVersionUID = 1L;

    public Integer getPost_id() {
        return post_id;
    }

    public void setPost_id(Integer post_id) {
        this.post_id = post_id;
    }

    public Integer getPost_user_id() {
        return post_user_id;
    }

    public void setPost_user_id(Integer post_user_id) {
        this.post_user_id = post_user_id;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        PostKey other = (PostKey) that;
        return (this.getPost_id() == null ? other.getPost_id() == null : this.getPost_id().equals(other.getPost_id()))
            && (this.getPost_user_id() == null ? other.getPost_user_id() == null : this.getPost_user_id().equals(other.getPost_user_id()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getPost_id() == null) ? 0 : getPost_id().hashCode());
        result = prime * result + ((getPost_user_id() == null) ? 0 : getPost_user_id().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", post_id=").append(post_id);
        sb.append(", post_user_id=").append(post_user_id);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}